<!DOCTYPE html>
<html>
    <head>
        <title>Player SCORM</title>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    
        <script language="JavaScript">
            
                // unload
                $(window).unload(function() {
                    alert('LALA.');
                    API.LMSFinish('');
                });

             	// clear database for this SCOInstance
		function clearDB() {
			var SCOInstanceID = document.getElementById("dataForm").SCORMInst.value;
			document.getElementById("monitor").src  = ".cleardb.php?SCOInstanceID="+SCOInstanceID;
		}

		// show database contents for this SCOInstance
		function showDB() {
			var SCOInstanceID = document.getElementById("dataForm").SCORMInst.value;
			document.getElementById("monitor").src  = ".showdb.php?SCOInstanceID="+SCOInstanceID;
		}
             
        </script>
   
    </head>
    <body>
    
        <div id="SCORMframeset">
            <iframe name="API" id="API" src="./api.php?SCOInstanceID={$SCOInstanceID}" height=0 width=0></iframe>
            <iframe name="scorm" id="scorm" src="{$urlSCORM}" height=800 width=1024></iframe>
        </div>

        <p><a href="javascript:API.LMSFinish('');">Terminar SCORM</a></p>
        
        <br>
        
        <div>
            <iframe name="monitor" id="monitor" src="" height=400 width=600></iframe>
        </div>
        
    </body>
</html>
